package com.example.source.spring.autowire;

import org.springframework.beans.factory.InitializingBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Component;

@Component
public class AutowiredBean implements InitializingBean {
    @Autowired
    @Qualifier
    AutowiredInterface autowiredInterface;

    @Autowired
    AutowiredBean autowiredBean;

    @Override
    public void afterPropertiesSet() throws Exception {
        System.out.println(autowiredInterface.toString());
    }
}
